from fastapi import Request, APIRouter
from fastapi.responses import HTMLResponse, FileResponse

# 创建路由实例
router = APIRouter(prefix="/auth", tags=["认证视图"])


@router.get("/login", response_class=HTMLResponse)
async def login_view(request: Request):
    """
    用户登录页面
    """
    return FileResponse("templates/auth/login.html")


@router.get("/register", response_class=HTMLResponse)
async def register_view(request: Request):
    """
    用户注册页面
    """
    return FileResponse("templates/auth/register.html")